package com.uum.mq.api;

import com.uum.mq.api.fallback.MqFeignFallBackClient;
import com.uum.common.core.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@FeignClient(value = "uum-mq", fallback = MqFeignFallBackClient.class)
public interface MqFeignClient {

    @GetMapping("/api/v1/mq/sendActivateEmail")
    Result sendActivateEmail(@RequestParam String nickname,@RequestParam String username,@RequestParam String token);

    @GetMapping("/api/v1/mq/sendBlog")
    Result sendBlog(@RequestParam Long blogId, @RequestParam String title);

    @DeleteMapping("/api/v1/user/msg/readAll")
    Result readAll(@RequestParam Long userId);

    @PostMapping("/api/v1/user/msg/saveReadMsgByUser")
    Result saveReadMsgByUser(@RequestParam Long userId);

    @PostMapping("/api/v1/user/msg/delMsgByUserId")
    Result delMsgByUserId(@RequestBody List<String> userId);

}
